package org.backend.canteenbackend.persistence;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;
import org.backend.canteenbackend.entity.Profile;
import org.springframework.stereotype.Repository;

@Repository
public interface ProfileMapper extends BaseMapper<Profile> {
    //更新语言
    @Update("UPDATE profile SET langpref = #{language} WHERE userid = #{userId}")
    int updateUserLanguage(@Param("userId") String userId, @Param("language") String language);
}
